package com.zretc;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.EnableAspectJAutoProxy;
import org.springframework.scheduling.annotation.EnableAsync;

/**
 * 系统模块
 * 
 *
 */
// 表示通过aop框架暴露该代理对象,AopContext能够访问
@EnableAspectJAutoProxy(exposeProxy = true)
// 指定要扫描的Mapper类的包的路径
@MapperScan("com.zretc.**.mapper")
// 开启线程异步执行
@EnableAsync
@EnableFeignClients
@SpringBootApplication
public class AdminSystemApplication implements CommandLineRunner
{
    public static void main(String[] args) {
        SpringApplication.run(AdminSystemApplication.class, args);
    }

    @Value("${aaa}")
    String name;
    @Override
    public void run(String... args) throws Exception {
        System.out.println("===============================");
        System.out.println(name);
        System.out.println("===============================");
    }
}
